package com.bzm.common.response;

import java.io.Serializable;

public class JsonPagesResult<T> implements Serializable{

	/**
	 * 
	 */
	private static final long serialVersionUID = -1065470642341278775L;

	/**
	 * 返回数据
	 */
    private T data;
    
    /**
     * 错误码
     */
    private Integer code;
    
    /**
     * 描述信息
     */
    private String msg;
    
    /**
     * 总数量
     */
    private Long total;
    
    /**
     * 总页数
     */
    private int pages;
    
    public JsonPagesResult(){
    	
    }
    
    public JsonPagesResult(T data,HttpCode httpCode,Long total,int pages) {
        this.data = data;
        this.code = httpCode.getCode();
        this.msg = httpCode.getMsg();
        this.total=total;
        this.pages=pages;
    }

    public T getdata() {
        return data;
    }

    public void setdata(T data) {
        this.data = data;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

    public Long getTotal() {
        return total;
    }

    public void setTotal(Long total) {
        this.total = total;
    }

	public int getPages() {
		return pages;
	}

	public void setPages(int pages) {
		this.pages = pages;
	}
    
}
